package ca.liu.study.springdata.jpa.repository;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import ca.liu.study.springdata.jpa.domain.Teacher;

public interface TeacherRepository extends JpaRepository<Teacher, Long> {

	@Query("select t from Teacher t where t.email = :email")
	public Teacher findByEmail(@Param("email") String email);
}
